Replace "Force Dark Mode" with dynamic Appearance setting (System/Light/Dark)#505
Merged
marionbarker merged 5 commits intoloopandlearn:devfrom Jan 20, 2026
Merged
Replace "Force Dark Mode" with dynamic Appearance setting (System/Light/Dark)#505marionbarker merged 5 commits intoloopandlearn:devfrom
marionbarker merged 5 commits intoloopandlearn:devfrom
Conversation
Change to follow system settings and switch without restart
Fix dataString unreliability issue
Update BGData.swift
Collaborator
|
Thank you for your contribution.
Please read the README file: https://github.com/loopandlearn/LoopFollow?tab=readme-ov-file#for-developers |
8 tasks
marionbarker
requested changes
Jan 18, 2026
Collaborator
marionbarker
left a comment
There was a problem hiding this comment.
I tested this and it works as expected. The selection of system, light and dark is immediately updated.
I am assuming it was a design choice that the Snooze screen should always be dark.
Remove mixed pull request
remove incorrect edits to DEVELOPMENT_TEAM variables
marionbarker
approved these changes
Jan 19, 2026
Collaborator
marionbarker
left a comment
There was a problem hiding this comment.
Thanks for the fixes. I approve this based on test and review.
One small nit for LoopFollow.xcodeproj/project.pbxproj
- You added white space at the end of "$(LF_DEVELOPMENT_TEAM)";.
- If you want to fix that, it will be a touch cleaner but I won't hold the merge
- Thanks for finding and fixing the duplicate lines for URLTokenValidationView.swift
bjorkert
approved these changes
Jan 20, 2026
codebymini
pushed a commit
that referenced
this pull request
Jan 31, 2026
…ht/Dark) (#505) Co-authored-by: hmatax-tom <tom@hma.tax>
codebymini
pushed a commit
that referenced
this pull request
Jan 31, 2026
…ht/Dark) (#505) Co-authored-by: hmatax-tom <tom@hma.tax>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This PR replaces the legacy "Force Dark Mode (restart app)" toggle with a proper Appearance picker offering three options: System, Light, and Dark. Changes now apply immediately without requiring an app restart, and the app properly responds to iOS/MacOS system appearance changes when in "System" mode.
Before:
After:
Test plan
Technical Details
New File:
AppearanceMode.swiftNew enum providing helpers for both SwiftUI and UIKit:
Reactive Updates
UIKit view controllers subscribe to appearance changes via Combine for immediate updates without restart.
System Appearance Detection
When in "System" mode,
MainViewControllerdetects iOS/MacOS appearance changes viatraitCollectionDidChangeand broadcasts a notification so all other view controllers update accordingly.Migration
forceDarkMode = true→appearanceMode = .darkforceDarkMode = false→appearanceMode = .system.systemFiles Changed
Helpers/AppearanceMode.swiftStorage/Storage.swiftforceDarkModeBool →appearanceModeenumStorage/Storage+Migrate.swiftSettings/GeneralSettingsView.swiftpreferredColorSchememodifierSwiftUI Views Updated (16 files)
AddAlarmSheet.swiftAlarmEditor.swiftAlarmListView.swiftAlarmSettingsView.swiftAlarmsContainerView.swiftBackgroundRefreshSettingsView.swiftSimpleQRCodeScannerView.swiftInfoDisplaySettingsView.swiftLogView.swiftNightscoutSettingsView.swiftRemoteSettingsView.swiftAdvancedSettingsView.swiftCalendarSettingsView.swiftContactSettingsView.swiftDexcomSettingsView.swiftGraphSettingsView.swiftTabCustomizationModal.swiftUIKit View Controllers Updated (7 files)
MainViewController.swift- Central coordinator, updates window-level styleSettingsViewController.swiftMoreMenuViewController.swiftNightscoutViewController.swiftAlarmViewController.swiftRemoteViewController.swiftSnoozerViewController.swift